package sys_error

// 没有找到异常
//补充一些错误代码什么的 ErrorCode

var NOT_FOUND_ERR = &NotFountError{"NotFountError"}

type NotFountError struct {
	Cause string
}

func (n *NotFountError) Error() string {
	return n.Cause
}

func NewNotFountErr(msg string) error {
	return &NotFountError{msg}
}

func IsNotFoundErr(err error) bool {
	switch err.(type) {
	case *NotFountError:
		return true
	default:
		return false
	}
}
